/**
 * 作者: wgx
 * 日期: 2025-04-29 10:50:50
 * 备注: 大世界雷达等级配置表
 */
package com.motu.monstercity.server.game.commondata.world;

import io.vertx.core.json.JsonObject;

public class WorldRadarModel {
    protected int level; // 等级
    protected String upgradeConsume; // 升级时的消耗道具配置
    protected int eventShowNum; // 最多显示的事件数量
    protected int eventRefreshNum; // 每次刷新新增事件数量
    protected String eventFixed; // 升级时刷新的固定事件ID
    protected int eventGroup; // 随机事件组ID
    protected String eventRate; // 每次新增事件各品质权重 (左往右分别是1品质~6品质事件的随机权重)
    protected int powerAdd; // 战力加成固定值
    protected String reward; // 奖励道具
    protected int urgentEventRate; // 触发紧急事件的概率 (10000表示100%)
    protected int urgentEventGroup; // 紧急事件的随机组 (关联到world_event表的对应随机事件组字段。)
    protected int urgentEventLimit; // 今日触发紧急事件的次数上限

    public WorldRadarModel() {
    }

    public WorldRadarModel(JsonObject obj) {
        level = obj.containsKey("level") ? obj.getInteger("level") : 0;
        upgradeConsume = obj.containsKey("upgrade_consume") ? obj.getString("upgrade_consume") : "";
        eventShowNum = obj.containsKey("event_show_num") ? obj.getInteger("event_show_num") : 0;
        eventRefreshNum = obj.containsKey("event_refresh_num") ? obj.getInteger("event_refresh_num") : 0;
        eventFixed = obj.containsKey("event_fixed") ? obj.getString("event_fixed") : "";
        eventGroup = obj.containsKey("event_group") ? obj.getInteger("event_group") : 0;
        eventRate = obj.containsKey("event_rate") ? obj.getString("event_rate") : "";
        powerAdd = obj.containsKey("power_add") ? obj.getInteger("power_add") : 0;
        reward = obj.containsKey("reward") ? obj.getString("reward") : "";
        urgentEventRate = obj.containsKey("urgent_event_rate") ? obj.getInteger("urgent_event_rate") : 0;
        urgentEventGroup = obj.containsKey("urgent_event_group") ? obj.getInteger("urgent_event_group") : 0;
        urgentEventLimit = obj.containsKey("urgent_event_limit") ? obj.getInteger("urgent_event_limit") : 0;
    }

    public int getLevel() {
        return level;
    }

    public String getUpgradeConsume() {
        return upgradeConsume;
    }

    public int getEventShowNum() {
        return eventShowNum;
    }

    public int getEventRefreshNum() {
        return eventRefreshNum;
    }

    public String getEventFixed() {
        return eventFixed;
    }

    public int getEventGroup() {
        return eventGroup;
    }

    public String getEventRate() {
        return eventRate;
    }

    public int getPowerAdd() {
        return powerAdd;
    }

    public String getReward() {
        return reward;
    }

    public int getUrgentEventRate() {
        return urgentEventRate;
    }

    public int getUrgentEventGroup() {
        return urgentEventGroup;
    }

    public int getUrgentEventLimit() {
        return urgentEventLimit;
    }

}
